import React, { useEffect, forwardRef } from 'react'
import { Modal } from 'antd'
import BloodRelationshipMap from './bloodRelationshipMap'

const ConsanguinityModal = (props) => {
  const {
    visible, onClose, obj,
  } = props

  useEffect(() => {
  }, [])

  const closeModal = () => {
    onClose && onClose()
  }

  return (
    <Modal
      title="查看血缘"
      footer={null}
      visible={visible}
      onCancel={closeModal}
      width={1360}
      destroyOnClose
    >
      <BloodRelationshipMap obj={obj} height={900} />
    </Modal>
  )
}

export default forwardRef((props, ref) => <ConsanguinityModal {...props} refInstance={ref} />)
